package org.quipu.dto;

public class TagDto extends UniqueTitledDto implements Cloneable {

    private Long bookId;
    private long frequency = 0;

    public TagDto() {
    }

    public TagDto(Long bookId, Long id, String title, long frequency) {
        super(id, title);
        this.bookId = bookId;
        this.frequency = frequency;
    }

    public Long getBookId() {
        return bookId;
    }

    public void setBookId(Long bookId) {
        this.bookId = bookId;
    }

    public long getFrequency() {
        return frequency;
    }

    public void setFrequency(long frequency) {
        this.frequency = frequency;
    }

//    @Override
    public Object clone() {
        TagDto tag = new TagDto();
        tag.setId(getId());
        tag.setBookId(bookId);
        tag.setTitle(getTitle());
        tag.setFrequency(frequency);
        return tag;
    }
}
